var addEvent = function ( el, type, listener ) {
    if (el.addEventListener) {
        el.addEventListener(type, listener, false);
    } else if (el.attachEvent) {
        el.attachEvent("on" + type, listener);
    } else {
        el["on" + type] = listener;
    }
    return el;
}
var removeEvent = function ( el, type, listener ) {
    if(window.detachEvent){
        el.detachEvent(type,listener)
    }else{
        el.removeEventListener(type,listener)
    }
    return el;
}

export {
    addEvent,
    removeEvent
}